package com.utrailer.wlt.gateway;

import com.utrailer.wlt.gateway.filter.RequestLogGlobalFilter;
import com.utrailer.wlt.gateway.filter.ResponseLogGlobalFilter;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Bean;


/**
 * TODO
 *
 * @author Chen Song
 * @since
 */
@SpringBootApplication
@EnableDiscoveryClient
public class Application {

    public static void main(String[] args) {
        SpringApplication.run(Application.class, args);
    }

    /*@Bean
    public CacheRequestFilter cacheRequestFilter() {
        return new CacheRequestFilter();
    }

    @Bean
    public RequestLogFilter requestLogFilter() {
        return new RequestLogFilter();
    }*/

    @Bean
    public RequestLogGlobalFilter requestLogGlobalFilter() {
        return new RequestLogGlobalFilter();
    }



    @Bean
    public ResponseLogGlobalFilter responseLogGlobalFilter() {
        return new ResponseLogGlobalFilter();
    }
}
